package com.first.config;

import org.springframework.amqp.core.AmqpTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class TestSender {

    @Autowired
    private AmqpTemplate amqpTemplate;

    public void sendMsg(){
        amqpTemplate.convertAndSend("test","这是一条测试消息！！");
    }
}
